package com.ruoyi.platform.service.impl;

import java.util.List;
import com.ruoyi.common.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.platform.mapper.MAttachmentMapper;
import com.ruoyi.platform.domain.MAttachment;
import com.ruoyi.platform.service.IMAttachmentService;

/**
 * 【请填写功能名称】Service业务层处理
 * 
 * @author dataControl
 * @date 2025-09-15
 */
@Service
public class MAttachmentServiceImpl implements IMAttachmentService 
{
    @Autowired
    private MAttachmentMapper mAttachmentMapper;

    /**
     * 查询【请填写功能名称】
     * 
     * @param attachmentId 【请填写功能名称】主键
     * @return 【请填写功能名称】
     */
    @Override
    public MAttachment selectMAttachmentByAttachmentId(String attachmentId)
    {
        return mAttachmentMapper.selectMAttachmentByAttachmentId(attachmentId);
    }

    /**
     * 查询【请填写功能名称】列表
     * 
     * @param mAttachment 【请填写功能名称】
     * @return 【请填写功能名称】
     */
    @Override
    public List<MAttachment> selectMAttachmentList(MAttachment mAttachment)
    {
        return mAttachmentMapper.selectMAttachmentList(mAttachment);
    }

    /**
     * 新增【请填写功能名称】
     * 
     * @param mAttachment 【请填写功能名称】
     * @return 结果
     */
    @Override
    public int insertMAttachment(MAttachment mAttachment)
    {
        mAttachment.setCreateTime(DateUtils.getNowDate());
        return mAttachmentMapper.insertMAttachment(mAttachment);
    }

    /**
     * 修改【请填写功能名称】
     * 
     * @param mAttachment 【请填写功能名称】
     * @return 结果
     */
    @Override
    public int updateMAttachment(MAttachment mAttachment)
    {
        return mAttachmentMapper.updateMAttachment(mAttachment);
    }

    /**
     * 批量删除【请填写功能名称】
     * 
     * @param attachmentIds 需要删除的【请填写功能名称】主键
     * @return 结果
     */
    @Override
    public int deleteMAttachmentByAttachmentIds(String[] attachmentIds)
    {
        return mAttachmentMapper.deleteMAttachmentByAttachmentIds(attachmentIds);
    }

    /**
     * 删除【请填写功能名称】信息
     * 
     * @param attachmentId 【请填写功能名称】主键
     * @return 结果
     */
    @Override
    public int deleteMAttachmentByAttachmentId(String attachmentId)
    {
        return mAttachmentMapper.deleteMAttachmentByAttachmentId(attachmentId);
    }
}
